package com.hl.hospital.controller;

import com.hl.hospital.config.Constants;
import com.hl.hospital.dao.*;
import com.hl.hospital.entity.*;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

import java.util.List;

@Controller
public class WZController {

    @Autowired
    private WzSbsyxxMapper wzSbsyxxMapper;
    @Autowired
    private WzSbxxMapper wzSbxxMapper;
    @Autowired
    private WzSbwxjlMapper wzSbwxjlMapper;
    @Autowired
    private WzSbzjxxMapper wzSbzjxxMapper;
    @Autowired
    private WzWzjhxxMapper wzWzjhxxMapper;
    @Autowired
    private WzWzslxxMapper wzWzslxxMapper;
    @Autowired
    private WzWzxxMapper wzWzxxMapper;
    @Autowired
    private WzWzsjcrlxxMapper wzWzsjcrlxxMapper;
    @Autowired
    private WzWzkcxxMapper wzWzkcxxMapper;

    @RequestMapping(value = "wzsbsyxx",method = RequestMethod.GET)
    public String Wzsbsyxx(Model model)
    {
        List<WzSbsyxx> wzsbsyxx= wzSbsyxxMapper.selectAll();
        model.addAttribute(Constants.WZSBSYXX,wzsbsyxx);
        return "wzsbsyxx";
    }

    @RequestMapping(value = "wzsbxx",method = RequestMethod.GET)
    public String Wzsbxx(Model model)
    {
        List<WzSbxx> wzsbxx= wzSbxxMapper.selectAll();
        model.addAttribute(Constants.WZSBXX,wzsbxx);
        return "wzsbxx";
    }

    @RequestMapping(value = "wzsbwxjl",method = RequestMethod.GET)
    public String Wzsbwxjl(Model model)
    {
        List<WzSbwxjl> wzsbwxjl= wzSbwxjlMapper.selectAll();
        model.addAttribute(Constants.WZSBWXJL,wzsbwxjl);
        return "wzsbwxjl";
    }

    @RequestMapping(value = "wzsbzjxx",method = RequestMethod.GET)
    public String Wzsbzjxx(Model model)
    {
        List<WzSbzjxx> wzsbzjxx= wzSbzjxxMapper.selectAll();
        model.addAttribute(Constants.WZSBZJXX,wzsbzjxx);
        return "wzsbzjxx";
    }

    @RequestMapping(value = "wzjhxx",method = RequestMethod.GET)
    public String Wzjhxx(Model model)
    {
        List<WzWzjhxx> wzjhxx= wzWzjhxxMapper.selectAll();
        model.addAttribute(Constants.WZWZJHXX,wzjhxx);
        return "wzjhxx";
    }

    @RequestMapping(value = "wzkcxx",method = RequestMethod.GET)
    public String Wzkcxx(Model model)
    {
        List<WzWzkcxx> wzkcxx= wzWzkcxxMapper.selectAll();
        model.addAttribute(Constants.WZWZKCXX,wzkcxx);
        return "wzkcxx";
    }

    @RequestMapping(value = "wzsjcrlxx",method = RequestMethod.GET)
    public String Wzsjcrlxx(Model model)
    {
        List<WzWzsjcrlxx> wzsjcrlxx= wzWzsjcrlxxMapper.selectAll();
        model.addAttribute(Constants.WZWZSJCRLXX,wzsjcrlxx);
        return "wzsjcrlxx";
    }

    @RequestMapping(value = "wzslxx",method = RequestMethod.GET)
    public String Wzslxx(Model model)
    {
        List<WzWzslxx> wzslxx= wzWzslxxMapper.selectAll();
        model.addAttribute(Constants.WZWZSLXX,wzslxx);
        return "wzslxx";
    }

    @RequestMapping(value = "wzxx",method = RequestMethod.GET)
    public String Wzxx(Model model)
    {
        List<WzWzxx> wzxx= wzWzxxMapper.selectAll();
        model.addAttribute(Constants.WZWZXX,wzxx);
        return "wzxx";
    }
}
